<?php
namespace Seller\Model;
use Think\Model\ViewModel;

class UpgradeViewModel extends ViewModel
{
    public $viewFields = array(

        'agent_upgrade' => array(
            'up_id','agent_id' ,'up_time' ,'rank_id' ,'audit_manager' ,'audit_time', 'is_adopt',
            'remark', 'audit_remark', 'old_rank',
            '_type' => 'LEFT'
        ),
        'agent' => array(
            'agent_name','mobile' ,'shop_id',
            '_on' => 'agent.agent_id = agent_upgrade.agent_id' ,
            '_type' => 'LEFT'
        ),
        'agent_rank' => array(
            'rank_name', 'welfare',
            '_on' => 'agent_rank.rank_id = agent_upgrade.rank_id' ,
            '_type' => 'LEFT'
        ),
        'manager' => array(
            'name' ,
            '_on' => 'manager.id = agent_upgrade.audit_manager' ,
            '_type' => 'LEFT'
        ),
    );
}